 {literal}
<script type="text/javascript">
$(document).ready(function(){
    
    $('input#checkAllTestItemCheckbox').bind('click',function(){
    	 if($(this).is(':checked') == true) {
    		 $("input:checkbox[name='testItemDoneCheckbox']").each(function() {
        		 $(this).attr('checked',true);
    		 });
    	 } else {
    		 $("input:checkbox[name='testItemDoneCheckbox']").each(function() {
                 $(this).attr('checked',false);
             });
    	 } 
    	 
    });
    
})
</script>
{/literal}
<div style="overflow: auto; height: 250px;">
<table class="grid" width="100%">
	<tr>
		<th style="width: 30px;" class="fist header">{translate}Order number{/translate}</th>
		<th class="header" style="width: 90px;">{translate}Test{/translate}</th>
		<th class="header" style="width: 90px;">{translate}Test detail{/translate}</th>
		<th style="width: 30px;" class="last header">{translate}Done{/translate} <input type="checkbox" id="checkAllTestItemCheckbox"></th>
	</tr>
	
	{assign var="count" value=1} 
	{foreach from=$assignedTestArr item=test}
	<tr>
		<td class="first">{$count++}</td>
		<td>{$test.test_name} :</td>
		<td>&nbsp;</td>
		<td class="last">&nbsp;</td>
	</tr>
	{foreach from=$test.test_item item=testItem}
	<tr>
		<td class="first">&nbsp;</td>
		<td >&nbsp;</td>
		<td style="font-style: italic;">{$testItem.name}</td>
		<td class="last" align="center"">
		  {if ($testItem.is_done == 0)} 
		  <input type="checkbox"  name="testItemDoneCheckbox" value="{$testItem.assigned_test_item_id}"> 
		  {else} 
		  <input type="checkbox"  name="testItemDoneCheckbox" value="{$testItem.assigned_test_item_id}" checked="checked"> 
		  {/if}
	    </td>
	</tr>
	{/foreach} {/foreach}
	
</table>
</div>
